package com.xujie.sportsmeeting.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * 裁判员VO
 */
@Data
@Schema(description = "裁判员VO")
public class JudgeVO {
    
    @Schema(description = "ID")
    private Long id;
    
    @Schema(description = "工号")
    private String workNumber;
    
    @Schema(description = "真实姓名")
    private String realName;
    
    @Schema(description = "性别：0-男，1-女")
    private Integer gender;
    
    @Schema(description = "手机号")
    private String phone;
    
    @Schema(description = "邮箱")
    private String email;
    
    @Schema(description = "部门")
    private String department;
    
    @Schema(description = "专业等级")
    private String professionalLevel;
    
    @Schema(description = "专业特长")
    private String speciality;
    
    @Schema(description = "资格证书")
    private String certificate;
    
    @Schema(description = "执裁经验年数")
    private Integer experienceYears;
    
    @Schema(description = "状态：0-禁用，1-正常")
    private Integer status;
    
    @Schema(description = "创建时间")
    private LocalDateTime createTime;
    
    @Schema(description = "更新时间")
    private LocalDateTime updateTime;
    
    /**
     * 获取性别文本
     */
    public String getGenderText() {
        return gender != null && gender == 1 ? "女" : "男";
    }
    
    /**
     * 获取状态文本
     */
    public String getStatusText() {
        return status != null && status == 1 ? "正常" : "禁用";
    }
}